package com.xjj.test.demo.testcase;

import com.sword.woodpecker.autotest.framework.testcase.TestCase;
import com.xjj.test.demo.DemoApplication;
import com.xjj.test.demo.service.IBaiDuService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.test.context.SpringBootTest;
import org.testng.annotations.BeforeMethod;
import org.testng.annotations.Test;

/**
 * 类描述:〈WEB-UI Demo〉
 */
@SpringBootTest(classes = {DemoApplication.class})
public class Demo3TC extends TestCase {

  @Autowired
  protected IBaiDuService iBaiDuService;

  @BeforeMethod
  public void openBaidu() {
    String url = "https://www.baidu.com";
    elementOperation.open(url);
  }

  @Test
  public void test1() {
    //百度搜索selenium
    String keyWord = "selenium";
    iBaiDuService.search(keyWord);
  }

}
